As the Internet and mobile networks have continued to proliferate in recent years, usage of packet-based networks utilizing Ethernet (registered trademark) technology and Internet Protocol (IP) technology is increasing on mobile carrier networks. Herein, a packet-based network designates a network in which data is transmitted and received in units of individual bundles, which are called packets. Note that in this specification, the terms packet and frame are treated as synonymous.
In a communication apparatus on a packet-based network such as an IP network or Ethernet (registered trademark) network, frames may be copied and transmitted from a plurality of ports. For example, there is the flooding, or in other words the transmission to multiple ports, of Ethernet (registered trademark) frames to a switch. As another example, there is the multicast transmission of IP frames for services such as video streaming services or IP television (IPTV) in a router.
Transmitting frames from multiple ports are conducted by grouping users, for example. In a switch, for example, users may be grouped under respective ports by grouping the ports according to a virtual local area network (VLAN). In a router, for example, users may be grouped using IP multicast groups.
FIG. 1 illustrates an exemplary network layout. A network 500 includes a plurality of communication apparatus 100 and a plurality of user terminals 200. The user terminals 200 are client devices with communication functions, such as personal computers, mobile phones, PDAs, and smartphones. The communication apparatus 100 receives frames transmitted from the user terminals 200, and forward frames on the basis of address and other information stored in the frames. For example, in the case where a user terminal 200 transmits an Ethernet (registered trademark) frame, a communication apparatus 100 forwards the frame on the basis of a MAC address stored in the received Ethernet (registered trademark) frame as address information. As another example, in the case where a user terminal 200 transmits an IP packet, a communication apparatus 100 forwards the packet on the basis of an IP address stored in the received IP packet as address information. Hereinafter, the case of the communication apparatus 100 forwarding Ethernet (registered trademark) frames will be described as an example.
FIG. 2 illustrates an exemplary configuration of a communication apparatus 100. The communication apparatus 100 includes a plurality of network interface (IF) cards 1, a switch (SW) card 2, and a control card 3. The IF cards 1 include ports, and circuits which provide functions for interfacing with external apparatus, functions for receiving frames, and functions for transmitting frames. The SW card 2 is connected to the IF cards 1 inside the communication apparatus 100 and exchanges data signals with the IF cards 1, and also includes circuits which provide switch functions for forwarding frames among the IF cards 1. The control card 3 is connected to the IF cards 1 and the SW card 2 inside the communication apparatus 100 and exchanges control signals with the IF cards 1 and the SW card 2, and also includes circuits which apply control over various settings in each card in the communication apparatus 100, alarms, and collection of statistical information. The control card 3 is also connected to an external terminal such as an external monitor.
The communication apparatus 100 may be an apparatus provided with bridging functions, for example. For example, examples of the communication apparatus 100 include Layer 2 switches, Layer 3 switches, and routers. In addition, the IF cards 1, the SW card 2, and the control card 3 may each be provided as modules or unit cards which can be freely inserted and removed from the communication apparatus 100, for example. Meanwhile, the IF cards 1, the SW card 2, and the control card 3 may also integrated with the motherboard or a mother card in the communication apparatus 100.
FIG. 3 illustrates Ethernet (registered trademark) frame formats. Hereinafter, “frame” will be used to indicate an Ethernet (registered trademark) frame, unless explicitly stated otherwise. FIG. 3 illustrates respective frame formats for a frame 91 without a virtual local area network (VLAN) tag, and a frame 92 with a single VLAN tag applied. It is possible for these frames to coexist on the same port of the communication apparatus 100.
The frame format of the frame 91 without a VLAN tag is as follows. MAC DA is a 6-byte field indicating the destination media access control (MAC) address. MAC SA is a 6-byte field indicating the source MAC address. E-TYPE is the Ethernet (registered trademark) type, and is a field storing the type of message stored in the subsequent protocol data unit (PDU). For example, a value of 0×0800 stored in the E-TYPE field indicates that the subsequent PDU is an IP version 4 (IPv4) packet. E-TYPE is a 2-byte field. Message types stored in the E-TYPE field are defined by the Internet Assigned Number Authority (IANA).
The PDU field stores a message for an upper layer, such as an IPv4 frame. The frame check sequence (FCS) field stores a CRC32 code used to detect errors in the frame. FCS is a 4-byte field.
The frame 92 with a single VLAN tag applied is a frame with one VLAN tag inserted between the MAC SA field and the E-TYPE field of the frame 91 without a VLAN tag. The VLAN tag includes a tag protocol ID (TPID) and a VLAN ID. The TPID is one of the Ethernet (registered trademark) types, and indicates that a VLAN ID is stored next. The TPID may be set to the value 0×8100, for example, which indicates IEEE 802.1Q. TPID is a 2-byte field. The VLAN ID stores a VLAN ID value used to identify the VLAN to which a user belongs. VLAN tags can be stacked consecutively.
The frame 91 without a VLAN tag may be used as a frame for a specific user or as a control frame transmitted and received among the communication apparatus 100 on a network port where frames from respective VLANs coexist, for example.
VLAN-tagged frames are used to assign different VLAN IDs to different users, such as assigning a VLAN ID=100 to a user A and a VLAN ID=200 to a user B, for example. By assigning different VLAN IDs to different users, it becomes possible to identify users on the network by their VLAN ID. In addition, users can be grouped by assigning the same VLAN ID to a plurality of users.
In the communication apparatus 100, frames received by the IF cards 1 are forwarded to the SW card 2. The SW card 2 stores information on a forwarding port which depends on the destination MAC address, and forwards the receive frames on the basis of this information.
In the case where forwarding port information corresponding to the destination MAC address included in a receive frame is not stored, the SW card 2 floods the VLAN domain corresponding to the receive frame with that receive frame. Flooding refers to the communication apparatus 100 copying and forwarding the receive frame on all ports belonging to the corresponding VLAN. The communication apparatus 100 stores a count of the number of copies of the flood frame as well as destination information which indicates information on the destination of the copied frame, and forwards frames on the basis of the destination information during flooding.
The destination information stores port numbers belonging to the corresponding VLAN ID in VLAN ID+receive port units. However, a client device existing under a receive port already receives the corresponding receive frame before the communication apparatus 100 receives that receive frame on that receive port. For this reason, if the SW card 2 also forwards a receive frame on a receive port and the receive frame is transmitted from the receive port, client devices under that receive port will receive the receive frame twice. In order to avoid receiving duplicate frames at a client device, port numbers belonging to the corresponding VLAN are stored in the destination information in VLAN ID+receive port units, excluding one's own receive port. For example, in the case where N ports in a communication apparatus 100 belong to a VLAN with VLAN ID=1, the communication apparatus stores N sets of destination information for the N ports, and each set of destination information includes N−1 other port numbers, with each port excluding itself.
For more information, see Japanese Laid-open Patent Application Publication No. 2005-57390 and Japanese Laid-open Patent Application Publication No. 2009-94832, for example.
In the case where the communication apparatus 100 supports many VLANs, or in the case where the communication apparatus 100 supports many ports, the amount of destination information managed within the apparatus increases, and there is a risk that the memory table footprint used to manage destination information may increase. Also, in the case where the communication apparatus 100 is not equipped with a large amount of memory, the supportable amount of destination information may be limited by the maximum available memory.
FIG. 4 illustrates an exemplary layout of a VLAN with VLAN ID=10 and exemplary destination information for respective ports belonging to a VLAN with VLAN ID=10 in a communication apparatus. In FIG. 4, the VLAN ID is labeled VID. Port #m on IF card #n is displayed as CnPm. Hereinafter, port #m on IF card #n may be referred to by CnPm in the specification.
In FIG. 4, the five ports C0P0, C1P1, C2P0, C3P0, and C3P1 belong to the VLAN with VLAN ID=10. The communication apparatus manages destination information with respect to these five ports for the VLAN with VLAN ID=10.
For example, in the case of receiving a frame with VLAN ID=10 on C0P0, the frame is transmitted to an SW card. In the case where forwarding port information corresponding to the destination MAC address included in the receive frame is not stored in the SW card, the SW card copies and transmits the receive frame to the ports included in the C0P0 destination information. As a result, copies of the receive frame addressed to C1P1, C2P0, C3P0, and C3P1 are transmitted from the SW card.
Also, in the case where C0P1 is added to the VLAN with VLAN ID=10, for example, the communication apparatus adds a sixth set of destination information taking C0P1 as a receive port for the VLAN with VLAN ID=10. Additionally, C0P1 is added to the five existing sets of destination information.
In the case where the communication apparatus supports many VLANs or many ports, the amount of destination information to modify increases as ports are added to or removed from VLANs, and the processing load imposed on the processor executing the software of the communication apparatus increases.
A communication apparatus may be able to support up to 4096 VLANs, for example. It is also possible to nest VLAN tags. For example, in the case where a frame is double-tagged with VLAN tags, it is possible to support approximately 17 million (4096×4096) VLANs. Furthermore, with regard to the number of ports, there exist communication apparatus into which 10 to 20 IF cards can be inserted, with each IF card supporting 64 Ethernet (registered trademark) ports, for example. Consequently, depending on the number of supported VLANs and ports, a communication apparatus may manage from hundreds of thousands to tens of millions of sets of destination information. In such cases, the memory footprint and the processing load on the processor executing the software become large. The foregoing describes an example of using the communication apparatus illustrated in FIG. 4 to manage ports belonging to a VLAN. However, the above is not limited to the management of ports belonging to VLANs, and similar events occur in the case of conducting communication while managing a plurality of grouped ports.